gdkgl: Use vfunc For Uploading Textures
authorChun-wei Fan <fanchunwei@src.gnome.org>
Wed, 17 Dec 2014 08:06:25 +0000 (16:06 +0800)
committerChun-wei Fan <fanchunwei@src.gnome.org>
Wed, 17 Dec 2014 08:06:25 +0000 (16:06 +0800)
commit9fd9f61b00f1dd7f61beb19cccea5767887a6a4b
treef7cfa3ec4743313b799b6396d77291c8bd28331d
parent6e7bf9ca7a8077452bb6cabcc81e8407e268cd99
gdkgl: Use vfunc For Uploading Textures

As the alignments, strides and image formats may be different across
platforms, make the texture upload a vfunc to allow backends to override
the GL commands for uploading textures for the software implementation for
gdk_gl_texture_from_surface(), if necessary.

Suggested by Alex to avoid copying non-trivial portions of code which would
then add maintainenace burden.

https://bugzilla.gnome.org/show_bug.cgi?id=740795
gdk/gdkgl.c
gdk/gdkglcontext.c
gdk/gdkglcontextprivate.h